#!/usr/bin/env python3
# -*- coding: utf-8 -*-

import abc
import os
from array import array

class ReadBuffer:
    @abc.abstractmethod
    def __init__ (self) -> None: ...
    @abc.abstractmethod
    def __del__ (self) -> None: ...
    @abc.abstractmethod
    def __len__ (self) -> int: ...
    @abc.abstractmethod
    def __iter__ (self) -> "ReadBuffer": ...
    @abc.abstractmethod
    def __next__ (self) -> int: ...
    @abc.abstractmethod
    def __enter__ (self) -> "ReadBuffer": ...
    @abc.abstractmethod
    def __exit__ (self, exc_type, exc_value, traceback) -> None: ...
    @abc.abstractmethod
    def tell (self) -> int: ...
    @abc.abstractmethod
    def seek (self, base: int, offset: int) -> None: ...
    @abc.abstractmethod
    def read (self) -> int: ...
    @abc.abstractmethod
    def peek (self, size: int) -> int: ...
    @abc.abstractmethod
    def eof (self) -> bool: ...
    @abc.abstractmethod
    def skipuntil (self, delimiter: int) -> None: ...
    @abc.abstractmethod
    def skipuntilnot (self, delimiter: int) -> None:...
    @abc.abstractmethod
    def _close (self) -> None: ...

class UnicodeReadBuffer(ReadBuffer):
    __slots__: tuple[str] = ("_data", "_pos")
    def __init__ (self, data: str|bytes|bytearray|array) -> None: ...
    def __del__ (self) -> None: ...
    def __len__ (self) -> int: ...
    def __getitem__ (self, index: int) -> int: ...
    def __iter__ (self) -> "UnicodeReadBuffer": ...
    def __next__ (self) -> int: ...
    def __enter__ (self) -> "UnicodeReadBuffer": ...
    def __exit__ (self, exc_type, exc_value, traceback) -> None: ...
    def eof (self) -> bool: ...
    def tell (self) -> int: ...
    def seek (self, base: int = os.SEEK_SET, offset: int = 0) -> None: ...
    def read (self) -> int: ...
    def peek (self, size: int = 1) -> int: ...
    def skipuntil (self, delimiter: int) -> None: ...
    def skipuntilnot (self, delimiter: int) -> None: ...
    def _close (self) -> None: ...
